﻿/*----------------------------------------------------------------
// Copyright (C) 2011 上海
// 版权所有。 
//
// 文件名：ManualEntryVM
// 文件功能描述：手工录入models层
//
// 
// 创建标识：2012-03-27 王冲
//
// 修改标识：
// 修改描述：
//
//
//----------------------------------------------------------------*/
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.Security;
using System.ComponentModel;
using System.ComponentModel.DataAnnotations;
using System.Web.Mvc;

namespace WaiGaoQiaoWeb.Models
{
    public class ManualEntryVM
    {
        /// <summary>
        /// 主键ID
        /// </summary>
        public int ID
        {
            get;
            set;
        }
        
        [Required(ErrorMessage = "日期不能为空")]
        [Remote("CheckDateNull", "ManualEntry", AdditionalFields = "DateEdit", HttpMethod = "POST", ErrorMessage = "日期不能为空")]
        /// <summary>
        /// 日期(精确到日)
        /// </summary>
        public string DateEdit
        {
            get;
            set;
        }
        /// <summary>
        /// 食堂
        /// </summary>
        public int MacID
        {
            get;
            set;
        }
        /// <summary>
        /// 餐次
        /// </summary>
        public int PeriodCode
        {
            get;
            set;
        }
        /// <summary>
        /// 名称
        /// </summary>
        public int DepositTypeID
        {
            get;
            set;
        }
        [Required(ErrorMessage = "数量不能为空")]
        [RegularExpression(@"^[1-9]\d*$", ErrorMessage = "数量必须是大于0的整数")]
        [Remote("CheckCountNull", "ManualEntry", AdditionalFields = "Count", HttpMethod = "POST", ErrorMessage = "数量不能为空")]
        /// <summary>
        /// 数量
        /// </summary>
        public string Count
        {
            get;
            set;
        }

        /// <summary>
        /// 菜单编号的集合
        /// </summary>
        public string MenuAll
        {
            get;
            set;
        }

        /// <summary>
        /// 左边的下拉列表
        /// </summary>
        public string leftbox
        {
            get;
            set;
        }
        /// <summary>
        /// 右边的下拉列表
        /// </summary>
        public string rightbox
        {
            get;
            set;
        }
        /// <summary>
        /// 食堂名称
        /// </summary>
        public string NODENAME
        {
            get;
            set;
        }
        /// <summary>
        /// 餐次
        /// </summary>
        public string PERIOD_NAME
        {
            get;
            set;
        }
        /// <summary>
        /// 名称
        /// </summary>
        public string DEPOSITNAME
        {
            get;
            set;
        }
    }
}